Accessing Rest API Services from Server-side Xbasic Code

Description

How to access Rest API Services using Xbasic.

How to Insert a REST API Call using the REST Reference Genie

  1. First open the Interactive window.

    images/ra2.png
  2. Right click the mouse buttons and select the 'Genies' option. Then select the 'REST Reference Call...' option.

    images/ra3.png
  3. The 'Pick a REST Service and Method' dialog will open. Select the Service that you want to view in the 'Service' menu. A list of methods for that service will appear in the 'Method' list on the right.

    images/ra4.png
  4. Select a method to call by highlighting it in the 'Method' list.

    images/ra5.png
  5. The code at the bottom of the 'Pick a REST Service and Method' dialog is the Xbasic that you will need to execute in order to call the selected method.

    images/ra6.png
  6. Once a rest service has been defined calling your service from Xbasic is very easy because the genie will generate the code for you.

Videos

Calling REST Services in Xbasic

In this video, we show how to use the REST Reference Call genie to make an API call to a REST Service using Xbasic.

2016-09-19